package cn.yitun.chat.yitunservercommonlib.converter.dto2po.contact;


import cn.yitun.chat.yitunservercommonlib.dataentity.dto.contact.ContactRelationDto;
import cn.yitun.chat.yitunservercommonlib.dataentity.po.contact.ContactRelationInfo;
import org.mapstruct.InheritInverseConfiguration;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper(componentModel = "spring")
public interface ContactRelationDto2PoConverter {

    ContactRelationDto2PoConverter INSTANCE = Mappers.getMapper(ContactRelationDto2PoConverter.class);

    ContactRelationDto do2dto(ContactRelationInfo info);

    List<ContactRelationDto> do2dto(List<ContactRelationInfo> doList);

    @InheritInverseConfiguration
    ContactRelationInfo dto2do(ContactRelationDto dto);
    @InheritInverseConfiguration
    List<ContactRelationInfo> dto2do(List<ContactRelationDto> dtoList);
}
